void main() {
  for (int i = 0; i <= 10; i++) {
    //偶数
    if (i % 2 == 0) {
      print(i);
    }
  }

  // 求1-100的和
  var sum = 0;
  for (var i = 0; i <= 100; i++) {
    // sum = sum + i;
    sum += i;
  }

  print(sum);

  print('---------------');

  int j = 1;
  while (j <= 10) {
    print(j);
    j++;
  }

  int a = 1;
  var suma = 0;
  do {
    suma += a;
    a++;
  } while (a <= 100);

  print(suma);

  print('--------break-------');

  var k = 1;
  for (var k = 0; k < 10; k++) {
    if (k == 4) {
      break;
    }
    print(k);
  }

  print('--------continue-------');

  for (var k = 0; k < 10; k++) {
    if (k == 4) {
      continue;
    }
    print(k);
  }
}
